import request from '@/utils/request'

// 查询字段下拉定义列表
export function listFieldDict(query) {
  return request({
    url: '/base/fieldDict/list',
    method: 'get',
    params: query
  })
}

// 查询字段下拉定义详细
export function getFieldDict(id) {
  return request({
    url: '/base/fieldDict/' + id,
    method: 'get'
  })
}

// 新增字段下拉定义
export function addFieldDict(data) {
  return request({
    url: '/base/fieldDict',
    method: 'post',
    data: data
  })
}

// 修改字段下拉定义
export function updateFieldDict(data) {
  return request({
    url: '/base/fieldDict',
    method: 'put',
    data: data
  })
}

// 删除字段下拉定义
export function delFieldDict(id) {
  return request({
    url: '/base/fieldDict/' + id,
    method: 'delete'
  })
}
